1. Field of the Invention
This invention generally relates to a method of video encoding, and especially to a method of video content complexity estimation and scene change detection.
2. Description of Related Art
Digital video usually contains a huge number of data. In order to save transmission bandwidth when transmitting video data, or to save storage space when storing video data, a video data must be compressed. The data compression is generally to remove surplus data from the video data for the purpose of reducing data. For example, when a previous frame is similar to the next frame, the first frame is kept and the like parts in the following frames are removed; that is, only the different parts are retained. Therefore, the amount of digital video data can be substantially reduced. For example, MPEG video compression standard is a popular video encoding method.
FIG. 1 is a schematic drawing of a conventional video encoding method. As shown in FIG. 1, motion estimation 110 compares digital video data DATA with reference frame data RF, and outputs motion estimation result 111. The conventional video content complexity estimation and the scene change detection 120 use the motion estimation result 111 to perform estimation and detection. According to the motion estimation result 111, motion compensation 130 compensates the received reference frame data RF and generates a compensation data 131. Transform coding 140 and quantization 150 can be performed after the digital video data DATA subtracts the compensation data 131, and further a quantized data 151 is generated. Further, according to the motion estimation result 112 and the quantized data 151, entropy coding 160, which is for example variable length coding, is performed, and a digital video data OUT which has been completely compressed is generated.
The above-mentioned reference frame data RF generally is a data 181 which is obtained after inverse-quatization 170 and inverse-transform coding 180 are performed to the quantized data 151. The reference frame data RF is obtained after a compensation data 132 is added to the data 181.
When digital video is applied at different environments, the different transmission and storage characteristics require a distinct encoding process. Especially, most transmission systems are constant bit rate (CBR) transmission. In order to maintain the CBR at video encoding process, most encoding devices must be equipped with a rate control module. In any rate control module, an important core element, video content complexity estimation device, must be included. A conventional rate control module performs the video content complexity estimation in a frame encoding loop (i.e. after motion estimation 110 as shown in FIG. 1). Generally speaking, in a video encoding device on a system on chip (SoC) platform, the video content complexity estimation is performed on MCU, and video-encoding loop (i.e. motion estimation, transform, quatization and entropy encoding) is performed on ASIC accelerator core. However, in the conventional technology, because the complexity estimation must be performed after the motion estimation is accomplished, data is frequently transmitted between the MCU and the ASIC calculation cores. In other words, a lot of time is spent on communication between the MCU and the ASIC calculation cores, and therefore the video encoding efficiency is decreased.